package com.sens.tables;

import com.litesuits.orm.db.annotation.Column;
import com.litesuits.orm.db.annotation.NotNull;
import com.litesuits.orm.db.annotation.Table;

@Table("MybankOrder")
public class MybankOrder extends BaseOrder<MybankOrder> {
    @Column("time")
    @NotNull
    private long time;
    @NotNull
    @Column("orderId")
    private String orderId;
    @NotNull
    @Column("amount")
    private double amount;
    @Column("currencyCode")
    private String currencyCode;
    @Column("tradeRemark")
    private String tradeRemark;
    @Column("ownerName")
    private String ownerName;
    @Column("ownerCardNo")
    private String ownerCardNo;
    @Column("tradeNo")
    private String tradeNo;
    @Column("tradeName")
    private String tradeName;
    @Column("oppositeCardNo")
    private String oppositeCardNo;
    @Column("oppositeName")
    private String oppositeName;

    public long getTime() {
        return time;
    }

    public void setTime(long time) {
        this.time = time;
    }

    public String getOrderId() {
        return orderId;
    }

    public void setOrderId(String orderId) {
        this.orderId = orderId;
    }

    public double getAmount() {
        return amount;
    }

    public void setAmount(double amount) {
        this.amount = amount;
    }

    public String getCurrencyCode() {
        return currencyCode;
    }

    public void setCurrencyCode(String currencyCode) {
        this.currencyCode = currencyCode;
    }

    public String getTradeRemark() {
        return tradeRemark;
    }

    public void setTradeRemark(String tradeRemark) {
        this.tradeRemark = tradeRemark;
    }

    public String getOwnerName() {
        return ownerName;
    }

    public void setOwnerName(String ownerName) {
        this.ownerName = ownerName;
    }

    public String getOwnerCardNo() {
        return ownerCardNo;
    }

    public void setOwnerCardNo(String ownerCardNo) {
        this.ownerCardNo = ownerCardNo;
    }

    public String getTradeNo() {
        return tradeNo;
    }

    public void setTradeNo(String tradeNo) {
        this.tradeNo = tradeNo;
    }

    public String getTradeName() {
        return tradeName;
    }

    public void setTradeName(String tradeName) {
        this.tradeName = tradeName;
    }

    public String getOppositeCardNo() {
        return oppositeCardNo;
    }

    public void setOppositeCardNo(String oppositeCardNo) {
        this.oppositeCardNo = oppositeCardNo;
    }

    public String getOppositeName() {
        return oppositeName;
    }

    public void setOppositeName(String oppositeName) {
        this.oppositeName = oppositeName;
    }

    @Override
    public int compareTo(MybankOrder o) {
        return (int) (o.time - this.time);
    }

    @Override
    public String requestQueryKey() {
        return orderId + amount;
    }
}